import request from '@/utils/request'

// 获取角色列表
export const getRoleList = () => {
    return request({
        url: 'user/getRoleList',
        method: 'get'
    });
}

// 获取用户列表
export const getUserList = (data) => {
    return request({
        url: 'user/getUserList',
        method: 'post',
        data
    });
}

// 新增用户
export const addUser = (data) => {
    return request({
        url: 'user/addUser',
        method: 'post',
        data
    });
}

// 编辑用户
export const editUser = (data) => {
    return request({
        url: 'user/editUser',
        method: 'post',
        data
    });
}

// 删除用户
export const delUser = (data) => {
    return request({
        url: 'user/delUser',
        method: 'post',
        data
    });
}